/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.sapra.echo;


import nextapp.echo2.app.Color;
import nextapp.echo2.app.Component;
import nextapp.echo2.app.Extent;
import nextapp.echo2.app.Font;
import nextapp.echo2.app.Label;
import nextapp.echo2.app.Table;
import nextapp.echo2.app.layout.TableLayoutData;
import nextapp.echo2.app.table.DefaultTableCellRenderer;
import nextapp.echo2.app.table.TableCellRenderer;

/**
 *
 * @author luiz
 */
class HeaderTable extends DefaultTableCellRenderer implements TableCellRenderer{

@Override
    public Component getTableCellRendererComponent(Table table,Object value,int column,int row){

        Label label=new Label(value.toString());
        TableLayoutData tld=new TableLayoutData();
        tld.setBackground(new Color(178,34,34));
        label.setForeground(Color.WHITE);
        label.setLayoutData(tld);
        label.setFont(new Font(Font.ARIAL, 1, new Extent(13)));

        return label;
    }
}
